<style>
#cover{display:none;position:fixed;left:0;top:0;z-index:18888;background-color:#000000;opacity:0.7;}
#guide{display:none;position:fixed;right:18px;top:5px;z-index:19999;}
#guide img{width:260px;height:180px;}
</style>
<div class="fui-page  fui-page-current">
	<div class='fui-content'>
		<div class="tips tips-yellow">
			<i class="fa fa-bullhorn"></i> {{pagedata.tips}}
		</div>
		<div ng-if="pagedata.item.type==3" class="weui_cells_title">《{{pagedata.item.gtype==1?'净邀请入群数':'净添加好友数'}}》任务数
			<a class="red bold pull-right">{{pagedata.item.usernum}}{{pagedata.item.gtype==1?'个':'人'}}</a>
		</div>
		<div class="weui_cells_title">文案内容
			<a href="javascript:;" ng-click="tool.clip(pagedata.item.content);pagedata.uplog();" class="label label-default pull-right">复制</a>
		</div>
		<div class="weui_cells" style="margin-top:0">
			<div class="weui_cell" style="padding-top:0">
					<div class="weui_cell_bd weui_cell_primary">
						{{pagedata.item.content}}
					</div>
			</div>
			<div ng-if="pagedata.item.image" class="weui_cell" style="padding-top:0">
					<div class="weui_cell_bd weui_cell_primary">
								<div class="weui_uploader">
									<div class="weui_uploader_bd">
										<ul class="weui_uploader_files" ng-click="pagedata.show_bigimage=true;pagedata.showimage=pagedata.item.image">
											<img class="weui_uploader_file" ng-src="{{tomedia(pagedata.item.image)}}">
										</ul>
									</div>
								</div>
					</div>
			</div>
		</div>
		<div ng-if="pagedata.item.tuwen.title" class="weui_cells_title">网页内容 
		<a href="javascript:;" ng-click="pagedata.open();" class="label label-info pull-right">转发</a>
		</div>
		<div ng-if="pagedata.item.tuwen.title" class="weui_cells" style="margin-top:0">
			<div class="weui_cell">
					<div class="weui_cell_bd weui_cell_primary">
						<div class="text">{{pagedata.item.tuwen.title}}</div>
						<div class="subtitle">{{pagedata.item.tuwen.desc}}</div>
					</div>
					<div ng-if="pagedata.item.tuwen.image" class="weui_cell_ft">
						<img style="margin-left: 5px;height: 44px;" ng-src="{{tomedia(pagedata.item.tuwen.image)}}">
					</div>
			</div>
		</div>
		<div ng-if="pagedata.item.images.length>0" class="weui_cells_title">图片内容</div>
		<div ng-if="pagedata.item.images.length>0" class="weui_cells" style="margin-top:0">
			<div class="weui_cell" style="padding-top:0">
					<div class="weui_cell_bd weui_cell_primary">
								<div class="weui_uploader">
									<div class="weui_uploader_bd">
										<ul class="weui_uploader_files">
											<img ng-click="pagedata.show_bigimage=true;pagedata.showimage=p" ng-repeat="p in pagedata.item.images track by $index" class="weui_uploader_file" ng-src="{{tomedia(p)}}"/>
										</ul>
									</div>
								</div>
					</div>
			</div>
		</div>
		<div ng-if="pagedata.item.type==1">
		<div class="fixed-title" style="margin-top:1rem">
			<span class="befirst spacing">
				 <span class="icon icon-fengexianzuo" style="font-size:2rem;color:#666"></span>
			 </span> 
				<span class="title-text bold" style="color:#333;line-height:2rem">{{pagedata.gtypetitle}}客户对象</span> 
				<span class="spacing">
					<span class="icon icon-fengexianyou" style="font-size:2rem;color:#666"></span>
				</span>
		</div>
		<div class='content-empty' ng-show="!pagedata.list || pagedata.list.length<=0">
				<i class='fa fa-comment-o'></i><br/>暂时没有任何任务对象!
		</div>
		<div style="padding:0 0.5rem">
			<div class='fui-list-group container' ng-show="pagedata.list.length>0" >
				<div class="fui-list goods-item" ng-repeat="item in pagedata.list">
					<div class="fui-list-media">
						<img ng-if="item.avatar" ng-src="{{tomedia(item.avatar)}}" class="round" style="width:2rem;height:2rem">
						<i ng-if="!item.avatar" class="icon icon-my2"></i>
					</div>
					<div class="fui-list-inner">
						<div class='title'>
							<span class="label label-success">{{item.name}}</span>
							<span class="red" style="margin-left:0.3rem">（{{item.gender}}）</span>
							<span class="gray" style="font-size:0.6rem;"> {{item.mobile}}</span>
						</div>
						<div ng-if="item.desc" class='gray'>{{item.desc}}<span class="red" style="margin-left:0.3rem">（{{item.desctime}}）</span></div>
						<div class='gray'>{{item.createtime}}</div>
					</div>
					<div class='fui-list-angle'>
						<!--<span ng-click="pagedata.gourl_scheme(item.external_userid)" class='label label-info' style="border-radius:0.2rem;">
						发送信息
						</span>-->
					</div>
				</div>
			</div>
		</div>
		</div>
	</div>
</div>
<div id="cover"></div>
<div id="guide"><img src="../addons/jy_scrmtask/resource/images/guide1.png"></div>
<!--图片放大-->
<div ng-if="pagedata.show_bigimage"  class="popup">
	<div class="popup-body">
	<div class="popup-center">
		<div ng-click="pagedata.show_bigimage=false" class="image" style="border-radius: 2rem; height:auto;background-position:center center">
			<img style="width:100%;height:auto" ng-src="{{tomedia(pagedata.showimage)}}">
		</div>
	</div>
	</div>
</div>
<script>
if(scope.pagedata.item.type==1){
	scope.tool.get_list('jy_scrmtask/log_item/userlist/tid='+scope.pagedata.item.id,true);
	scope.pagedata.scroll_bottom=function(){
		scope.tool.get_list('jy_scrmtask/log_item/userlist/tid='+scope.pagedata.item.id);
	}
}
scope.pagedata.open=function(){
	$("#cover").show();
	$("#guide").show();
}
scope.pagedata.uplog=function(){
	scope.post_json('jy_scrmtask/log_item/uplog/id='+scope.pagedata.log.id,{},function(res){
	});
}
$(function(){
		$("#invitation").on("click",function(){
			if($("#cover").css("display")=='none'){
				$("#cover").show();
				$("#guide").show();
			}
		})
		$("#cover").on("click",function(){
			$("#cover").hide();
			$("#guide").hide();
		})
})
</script>
<script>
scope.pagedata.gourl_scheme=function(external_userid){
	scope.get('//getscheme/userid='+external_userid,function(res){
		console.log(res);
		if(res.error==0){
			location.href = res.url
		}else{
			scope.message(res.msg);
		}
	});
}
scope.get('//getaddnum/id='+scope.pagedata.log.id,function(res){
});
</script>